home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Games Extra 1996 September
/
Amiga Games Extra CD-ROM 9-1996.iso
/
userbox
/
publicdomain
/
vim-4.2
/
src
/
addcr.c
< prev
next >
Wrap
C/C++ Source or Header
|
1996-06-09
|
414b
|
22 lines
/*
* This program, when compiled with Turbo-C, will make <LF> into <CR><LF>
*/
#include <stdio.h>
char buffer[1024];
main(argc, argv)
int argc;
char **argv;
{
int len;
while ((len = fread(buffer, 1, 1024, stdin)) > 0)
fwrite(buffer, 1, len, stdout);
if (ferror(stdin))
fprintf(stderr, "Error while reading\n");
if (ferror(stdout))
fprintf(stderr, "Error while writing\n");
}